﻿@using Ganss.Xss;
@model Personalblog.Model.Entitys.Messages
<div class="feedbackItem">
    <div class="feedbackListSubtitle">
        <div class="feedbackManage">
            <span class="comment_actions">
                <a class="comment_actions_link" href="#btnComment_div" onclick="Reply(@Model.Id,'@Model.Name','@Model.Email')" id="Reply">回复</a>
            </span>
        </div>
        <span class="comment_date">@Model.created_at</span>
        <span class="a_comment_author_5166961">@Model.Name</span>
    </div>
    <div class="feedbackCon">
        @{
            var sanitizer = new HtmlSanitizer();
            sanitizer.AllowedCssProperties.Clear(); // clear all allowed CSS properties
            sanitizer.AllowedCssProperties.Add("text-align"); 
            string sanitizedHtml = sanitizer.Sanitize(@Model.Message);
        }
        @Html.Raw(sanitizedHtml)
    </div>   
</div>
@if (Model.Replies.Any())
{
    @await Html.PartialAsync("Widgets/MsgBoxReplyList",Model.Replies)
}

